<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xmlns:ui="http://java.sun.com/jsf/facelets" xmlns:h="http://java.sun.com/jsf/html" xmlns:f="http://java.sun.com/jsf/core" xmlns:p="http://primefaces.org/ui">
<h:head>
	<title><h:outputText value="JEE7 application - " /><ui:insert name="title" /></title>
	<h:outputStylesheet library="medias/css" name="application.css" />
	<h:outputStylesheet library="medias/css" name="primefaces.css" />
</h:head>

<h:body>

	<p:layout fullPage="true">

		<p:layoutUnit position="north">
			<ui:include src="header.xhtml" />
		</p:layoutUnit>

		<p:layoutUnit position="west">
			<ui:include src="menu.xhtml" />
		</p:layoutUnit>

		<p:layoutUnit position="center">
			<p:growl autoUpdate="true" escape="false" life="10000" />
			<ui:insert name="content" />
		</p:layoutUnit>

		<p:layoutUnit position="south">
			<ui:include src="footer.xhtml" />
		</p:layoutUnit>

	</p:layout>

	<ui:insert name="dialog" />

	<h:form>
		<p:confirmDialog widgetVar="dialogConfirmationDeconnexion" showEffect="fade" closeOnEscape="true" header="Deconnexion">
			<f:facet name="message">
				<h:outputText value="Etes-vous sûr de vouloir vous deconnecter ? Tout travail non enregistré sera perdu." />
			</f:facet>
			<div align="right">
				<p:commandButton value="Annuler" icon="ui-icon-circle-close" oncomplete="PF('dialogConfirmationDeconnexion').hide()" />
				<p:commandButton value="Se deconnecter" icon="ui-icon-power" action="#{authentificationBean.doLogOut}" oncomplete="PF('dialogConfirmationDeconnexion').hide()" ajax="false" />
			</div>
		</p:confirmDialog>
	</h:form>

</h:body>

</html>
